package com.bailian.system.service.impl;

import java.util.List;
import com.bailian.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.bailian.system.mapper.BlParkConfigMapper;
import com.bailian.system.domain.BlParkConfig;
import com.bailian.system.service.IBlParkConfigService;

/**
 * 园区仓库配置Service业务层处理
 * 
 * @author bailian
 * @date 2025-08-04
 */
@Service
public class BlParkConfigServiceImpl implements IBlParkConfigService 
{
    @Autowired
    private BlParkConfigMapper blParkConfigMapper;

    /**
     * 查询园区仓库配置
     * 
     * @param configId 园区仓库配置主键
     * @return 园区仓库配置
     */
    @Override
    public BlParkConfig selectBlParkConfigByConfigId(Long configId)
    {
        return blParkConfigMapper.selectBlParkConfigByConfigId(configId);
    }

    /**
     * 查询园区仓库配置列表
     * 
     * @param blParkConfig 园区仓库配置
     * @return 园区仓库配置
     */
    @Override
    public List<BlParkConfig> selectBlParkConfigList(BlParkConfig blParkConfig)
    {
        return blParkConfigMapper.selectBlParkConfigList(blParkConfig);
    }

    /**
     * 新增园区仓库配置
     * 
     * @param blParkConfig 园区仓库配置
     * @return 结果
     */
    @Override
    public int insertBlParkConfig(BlParkConfig blParkConfig)
    {
        blParkConfig.setCreateTime(DateUtils.getNowDate());
        return blParkConfigMapper.insertBlParkConfig(blParkConfig);
    }

    /**
     * 修改园区仓库配置
     * 
     * @param blParkConfig 园区仓库配置
     * @return 结果
     */
    @Override
    public int updateBlParkConfig(BlParkConfig blParkConfig)
    {
        blParkConfig.setUpdateTime(DateUtils.getNowDate());
        return blParkConfigMapper.updateBlParkConfig(blParkConfig);
    }

    /**
     * 批量删除园区仓库配置
     * 
     * @param configIds 需要删除的园区仓库配置主键
     * @return 结果
     */
    @Override
    public int deleteBlParkConfigByConfigIds(Long[] configIds)
    {
        return blParkConfigMapper.deleteBlParkConfigByConfigIds(configIds);
    }

    /**
     * 删除园区仓库配置信息
     * 
     * @param configId 园区仓库配置主键
     * @return 结果
     */
    @Override
    public int deleteBlParkConfigByConfigId(Long configId)
    {
        return blParkConfigMapper.deleteBlParkConfigByConfigId(configId);
    }
}
